#include <iostream>
#include <thread>
#include <chrono>
#include <memory>
#include "log4cpp.h"

using namespace std;

#define LOG_MSG_LENGTH 1024

int main(int argc, char **argv)
{
    Log4cpp::Instance()->setConfigurationItems();

    while (true)
    {
        std::shared_ptr<char[]> ptrStr(new char[LOG_MSG_LENGTH]);
        for (int i = 0; i < LOG_MSG_LENGTH; i++)
        {
            ptrStr[i] = 'S';
        }

        HLD_LOG4CPLUS_TRACE(ptrStr);

        std::this_thread::sleep_for(std::chrono::milliseconds(500));
    }

    return 0;
}